package com.ltmonitor.jt808.protocol;

public class PostitionAdditional_RecorderSpeed implements
		IPositionAdditionalItem {
	public final int getAdditionalId() {
		return 0x03;
	}

	public final byte getAdditionalLength() {
		return 0x02;
	}

	/**
	 * 行驶记录功能获取的速度，WORD，1/10km/h
	 */

	private short recorderSpeed;

	public final short getRecorderSpeed() {
		return recorderSpeed;
	}

	public final void setRecorderSpeed(short value) {
		recorderSpeed = value;
	}

	public final byte[] WriteToBytes() {
		return BitConverter.GetBytes(getRecorderSpeed());
	}

	public final void ReadFromBytes(byte[] bytes) {
		setRecorderSpeed((short) BitConverter.ToUInt16(bytes, 0));
	}
}